﻿using Framework.Camera;
using System.Collections.Generic;

namespace VisionPlatform.BaseType
{
    /// <summary>
    /// 相机IO配置
    /// </summary>
    public class CameraLineConfig
    {
        /// <summary>
        /// 相机线
        /// </summary>
        public string Line { get; set; }

        /// <summary>
        /// IO模式
        /// </summary>
        public string LineMode { get; set; }

        /// <summary>
        /// IO触发源
        /// </summary>
        public string LineSource { get; set; }

        /// <summary>
        /// 创建CameraLineConfig新实例
        /// </summary>
        public CameraLineConfig()
        {

        }

        /// <summary>
        /// 创建CameraLineConfig新实例
        /// </summary>
        /// <param name="line"></param>
        /// <param name="lineMode"></param>
        /// <param name="lineSource"></param>
        public CameraLineConfig(string line, string lineMode, string lineSource)
        {
            Line = line;
            LineMode = lineMode;
            LineSource = lineSource;

        }
    }

    /// <summary>
    /// 相机配置参数
    /// </summary>
    public class CameraConfigParam
    {
        /// <summary>
        /// 像素格式
        /// </summary>
        public EPixelFormatType PixelFormat { get; set; }

        /// <summary>
        /// 触发模式
        /// </summary>
        public ETriggerModeStatus TriggerMode { get; set; }

        /// <summary>
        /// 触发源
        /// </summary>
        public ETriggerSource TriggerSource { get; set; }

        /// <summary>
        /// 有效触发信号(硬件)
        /// </summary>
        public ETriggerActivation TriggerActivation { get; set; }

        /// <summary>
        /// 曝光值
        /// </summary>
        public double ExposureTime { get; set; }

        /// <summary>
        /// 增益值
        /// </summary>
        public double Gain { get; set; }

        /// <summary>
        /// 相机线配置
        /// </summary>
        public List<CameraLineConfig> CameraLineConfigs { get; } = new List<CameraLineConfig>();
        
    }
}
